package saati.utils;

public class ArrayUtil {

    public static int findOccurrence(int[] arr, int numToFind) {
        int occurrence = 0;
        for (int i = 0; i < arr.length; i++) {
            if (arr[i] == numToFind) {
                occurrence++;
            }
        }
        return occurrence;
    }

    public static int[] getColumn(int[][] arr, int columnNumber) {
        int[] column = new int[arr.length];
        for (int i = 0; i < arr.length; i++) {
            column[i] = arr[i][columnNumber];
        }
        return column;
    }


}
